home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / include / gnome-vfs-module-2.0 / libgnomevfs / gnome-vfs-inet-connection.h < prev    next >
Encoding:
C/C++ Source or Header  |  2006-05-01  |  2.8 KB  |  74 lines

  1. /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
  2. /* gnome-vfs-inet-connection.h - Functions for creating and destroying Internet
  3.    connections.
  4.  
  5.    Copyright (C) 1999 Free Software Foundation
  6.  
  7.    The Gnome Library is free software; you can redistribute it and/or
  8.    modify it under the terms of the GNU Library General Public License as
  9.    published by the Free Software Foundation; either version 2 of the
  10.    License, or (at your option) any later version.
  11.  
  12.    The Gnome Library is distributed in the hope that it will be useful,
  13.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  15.    Library General Public License for more details.
  16.  
  17.    You should have received a copy of the GNU Library General Public
  18.    License along with the Gnome Library; see the file COPYING.LIB.  If not,
  19.    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  20.    Boston, MA 02111-1307, USA.
  21.  
  22.    Author: Ettore Perazzoli <ettore@gnu.org> */
  23.  
  24. #ifndef GNOME_VFS_INET_CONNECTION_H
  25. #define GNOME_VFS_INET_CONNECTION_H
  26.  
  27. #include <libgnomevfs/gnome-vfs-cancellation.h>
  28. #include <libgnomevfs/gnome-vfs-socket.h>
  29. #include <libgnomevfs/gnome-vfs-socket-buffer.h>
  30. #include <libgnomevfs/gnome-vfs-address.h>
  31.  
  32. G_BEGIN_DECLS
  33.  
  34. typedef struct GnomeVFSInetConnection GnomeVFSInetConnection;
  35.  
  36. GnomeVFSResult     gnome_vfs_inet_connection_create
  37.                     (GnomeVFSInetConnection **connection_return,
  38.                      const gchar *host_name,
  39.                      guint host_port,
  40.                      GnomeVFSCancellation *cancellation);
  41.  
  42. GnomeVFSResult   gnome_vfs_inet_connection_create_from_address
  43.                                         (GnomeVFSInetConnection **connection_return,
  44.                      GnomeVFSAddress         *address,
  45.                      guint                    host_port,
  46.                      GnomeVFSCancellation    *cancellation);
  47.  
  48. /* free the connection structure and close the socket */
  49. void         gnome_vfs_inet_connection_destroy
  50.                     (GnomeVFSInetConnection *connection,
  51.                      GnomeVFSCancellation *cancellation);
  52.  
  53. /* free the connection structure without closing the socket */
  54. void         gnome_vfs_inet_connection_free
  55.                     (GnomeVFSInetConnection *connection,
  56.                      GnomeVFSCancellation *cancellation);
  57.  
  58. GnomeVFSSocket * gnome_vfs_inet_connection_to_socket 
  59.                     (GnomeVFSInetConnection *connection);
  60.  
  61. GnomeVFSSocketBuffer *gnome_vfs_inet_connection_to_socket_buffer 
  62.                                         (GnomeVFSInetConnection *connection);
  63.  
  64. int gnome_vfs_inet_connection_get_fd    (GnomeVFSInetConnection *connection);
  65.  
  66. char *gnome_vfs_inet_connection_get_ip  (GnomeVFSInetConnection *connection);
  67.  
  68. GnomeVFSAddress *gnome_vfs_inet_connection_get_address
  69.                                         (GnomeVFSInetConnection *connection);
  70.  
  71. G_END_DECLS
  72.  
  73. #endif /* GNOME_VFS_INET_CONNECTION_H */
  74.